Skip to content

feat: Position & momentum unbounded operators#963

Open
gloges wants to merge 8 commits intoleanprover-community:masterfrom
gloges:xp-operators
Open

feat: Position & momentum unbounded operators#963
gloges wants to merge 8 commits intoleanprover-community:masterfrom
gloges:xp-operators

Conversation

@gloges
Copy link
Contributor

@gloges gloges commented Mar 1, 2026

Continues on from #957 and makes progress on #851.

Introduces schwartzEquiv, the LinearEquiv between Schwartz functions and their image in the Hilbert space, along with some basic properties. This bijection is then used to define three symmetric unbounded operators with Schwartz submodule for domain, using the previously-defined continuous linear maps on Schwartz functions. These are the position and momentum unbounded operators, defined component-wise, and the (regularized) radius operator to any real power.

There remains one sorry which will have to be revisited. Showing that the momentum operator on Schwartz functions is symmetric requires two results for Space.deriv: integration-by-parts over all of Space d and commutation through complex conjugation.

@morrison-daniel morrison-daniel self-assigned this Mar 1, 2026
@morrison-daniel morrison-daniel added the t-quantum-mechanics Quantum mechanics label Mar 1, 2026
@morrison-daniel
Copy link
Collaborator

Apologies for not getting to this sooner, but I have been thinking about your PR. I think everything you've done here is reasonable in terms of the existing API and how the literature is written but I wonder if it makes sense for us to change up how UnboundedOperator is defined to make things smoother for Lean formalization. What doesn't feel quite right to me is

/-- The position operators defined on the Schwartz submodule. -/
def positionOperatorSchwartz : schwartzSubmodule d →ₗ[ℂ] schwartzSubmodule d :=
  (schwartzEquiv (d := d)) ∘ₗ 𝐱[i].toLinearMap ∘ₗ (schwartzEquiv (d := d)).symm

Like I said, why you'd do this makes sense with how things are designed, but needing to use schwartzEquiv to move back and forth between the Schwartz subspace seems like a complication that is going to bite us in the long run. I wonder if it would make more sense to have UnboundedOperator between two different spaces, even if we only intend to use them between the same space because Lean sees the submodule it's defined on as a different space than the entire Hilbert space. So I'm thinking it might be smart to adjust the API before we get too deep.

Unfortunately that would delay this PR but I think it might save some headaches in the long run. Does this reasoning make sense, and do you think this would be a productive change?

@morrison-daniel morrison-daniel added the awaiting-author A reviewer has asked the author a question or requested changes label Mar 3, 2026
@jstoobysmith
Copy link
Member

@morrison-daniel Could you give your suggested definition for UnboundedOperator here?

@gloges
Copy link
Contributor Author

gloges commented Mar 4, 2026

I wonder if it would make more sense to have UnboundedOperator between two different spaces, even if we only intend to use them between the same space

I think this change,

structure UnboundedOperator ... extends LinearPMap ℂ HS1 HS2 where ...

could be done relatively easily, but this wouldn't remove the need to map between Schwartz maps and their $$L^2$$ equivalence classes. Maybe I have misunderstood your comment?

@morrison-daniel
Copy link
Collaborator

You are correct, I realized what I was suggesting wouldn't actually remove what I wanted to remove. I have a tendency to be overly cautious to whether something is being done in the best way which is overkill at this point... Ignore my previous statement I'll review, but it's already looking pretty good!


lemma schwartzIncl_injective {d : ℕ} : Function.Injective (schwartzIncl (d := d)) :=
injective_toLp (E := Space d) 2
variable {d : ℕ}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
variable {d : ℕ}
variable (d : ℕ)

I wonder if it'd make sense to make this explicit because, while d can be inferred when applying to a specific function, we're using it a lot for operators and need to include (d := d) a lot. I can see it either way, you can choose which you prefer.

You can also decide if you'd like to make the same change on the operators.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I figured out that writing schwartzEquiv.toLinearMap correctly infers d, so I think we can keep it implicit for now. The only place that (d := d) remains is in abbrev schwartzSubmodule.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-author A reviewer has asked the author a question or requested changes t-quantum-mechanics Quantum mechanics

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants